package com.qyhl.module_practice.team.list;


import com.qyhl.webtv.commonlib.entity.civilized.PracticeIsVolunteerBean;
import com.qyhl.webtv.commonlib.entity.civilized.PracticeTeamBean;

import java.util.List;

public class PracticeTeamListPresenter implements PracticeTeamListContract.PracticeTeamListPresenter {
    private PracticeTeamListModel mModel;
    private PracticeTeamListContract.PracticeTeamListView mView;

    PracticeTeamListPresenter(PracticeTeamListContract.PracticeTeamListView mView) {
        this.mView = mView;
        this.mModel = new PracticeTeamListModel(this);
    }


    @Override
    public void getList(String page, String instId, boolean isStreet) {
        mModel.getList(page, instId, isStreet);
    }

    @Override
    public void getVolTeamList(String volId) {
        mModel.getVolTeamList(volId);
    }

    @Override
    public void getIsVolunteer(String phone) {
        mModel.getIsVolunteer(phone);
    }

    @Override
    public void doSearch(String keyword, String page) {
        mModel.doSearch(keyword, page);
    }

    @Override
    public void setList(List<PracticeTeamBean> beanList, boolean isMore) {
        mView.setList(beanList, isMore);
    }

    @Override
    public void setSearchList(List<PracticeTeamBean> beanList, boolean isMore) {
        mView.setSearchList(beanList, isMore);
    }

    @Override
    public void setIsVolunteer(PracticeIsVolunteerBean bean) {
        mView.setIsVolunteer(bean);
    }

    @Override
    public void setError(String msg, boolean isMore) {
        mView.setError(msg, isMore);
    }
}
